LanguageExt.Core

LanguageExt.Core DataTypes SpanArray

Contents

struct SpanArray <A> Source #

Represents a mutable array type that can be sliced to return new versions of the array which represent subsections of the original but without copying to a new buffer. This means the underlying array is shared and vulnerable to data race issues and the commonly known issues of mutable structures.

It is primarily to facilitate super-fast algorithms that work on collections. The idea being that the algorithm knows about the issues of mutation and can avoid the problems whilst doing its thing, but also benefit from a more declarative style by using Take, Skip, Slice, Head, Tail, Elem etc.

Fields

field A[] Data Source #

field int Count Source #

Indexers

this [ A ] Source #

Properties

property SpanArray<A> Tail Source #

property A Head Source #

property A Last Source #

Methods

method Option<A> Elem (int index) Source #

method IEnumerator<A> GetEnumerator () Source #

method SpanArray<A> New (IEnumerable<A> sequence) Source #

method SpanArray<A> New (A[] data) Source #

method SpanArray<A> New (int n) Source #

method SpanArray<A> Slice (int index, int count) Source #

method SpanArray<A> Take (int n) Source #

method SpanArray<A> Skip (int n) Source #

method Unit UnsafeCopy (SpanArray<A> dest) Source #